namespace CSharpPro._1020;

class Student
{
    private string id;
    private string name;
    private int age;
    
    public Student(string id, string name, int age)
    {
        this.id = id;
        this.name = name;
        this.age = age;
    }
    public string Id
    {
        get { return id; }
        set { id = value; }
    }
    public string Name
    {
        get { return name; }
        set { name = value; }
    }
    public int Age
    {
        get { return age; }
        set { age = value; }
    }
    public void ShowInfo()
    {
        Console.WriteLine($"学号：{id}，姓名：{name}，年龄：{age}");
    }
}

class Program
{
    static void main(string[] args)
    {
        Student student1 = new Student("S001", "张三", 20);
        Student student2 = new Student("S002", "李四", 21);
        student1.ShowInfo();
        student2.ShowInfo();
        student2.Name = "王五";
        student2.Age = 22;
        student2.ShowInfo();
    }
}